package cn.springcloud.fix.server.api.log.feign.factory;

import cn.springcloud.fix.server.api.log.feign.OperateLogService;
import feign.hystrix.FallbackFactory;
import lombok.extern.slf4j.Slf4j;
import org.springframework.stereotype.Component;

@Slf4j
@Component
public class OperateLogFallbackFactory implements FallbackFactory<OperateLogService> {

    @Override
    public OperateLogService create(Throwable throwable) {
        log.error(throwable.getMessage(), throwable);
        return null;
    }
}
